package com.dky.satell.service;

import com.dky.satell.dto.ResultDto;
import com.dky.satell.entity.OfflineFile;
import com.github.pagehelper.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import org.springframework.web.multipart.MultipartFile;

import java.io.File;
import java.util.List;

/**
 *
 * @author mqc
 * @since 2021-04-25
 */
public interface OfflineFileService extends IService<OfflineFile> {

    /**
     * 新增
     * @param file
     * @param offlineFile
     * @return
     */
    ResultDto insert(MultipartFile file, OfflineFile offlineFile);

    /**
     * 新增
     * @param file
     * @param offlineFile
     * @return
     */
    ResultDto insert(File file, OfflineFile offlineFile, File schemaFile);

    /**
     * 根据资产名称模糊查询
     * @param name
     * @return
     */
    Page<OfflineFile> findFileByFileName(Integer pageNo, Integer pageSize,String name);

    /**
     * 根据id查看详情
     * @param id
     * @return
     */
    List<OfflineFile> selectOffLineFileById(Integer id);

    /**
     * 根据文件名查询
     * @param fileName
     * @return
     */
    OfflineFile selectOfflineFileByName(String fileName);


}
